<div class='span12'>
	<h1><a>Editar tipo de evento <?php echo $eventstype['EventsType']['name'];?></a></h1>
	<hr>
		<?php $options=array('type' => 'file','class' => 'form-horizontal','action'=>'eventstype_save_fields',
				'inputDefaults' => array(
				    'format' => array('before', 'label', 'between', 'input', 'error', 'after'),
				    'div' => array('class' => 'control-group'),
				    'label' => array('class' => 'control-label'),
				    'between' => '<div class="controls">',
				    'after' => '</div>',
				    'error' => array('attributes' => array('wrap' => 'span', 'class' => 'help-inline')),
				))?>
		<?php echo $this->Form->create('Events',$options); ?>
		<?php echo $this->Form->input('name',array( 'label' => array( 'text' => __('Nombre:'),'class' => 'control-label' )) ); ?>
		<?php echo $this->Form->input('order',array( 'label' => array( 'text' => __('Orden:'),'class' => 'control-label' )) ); ?>
		<?php echo $this->Form->input('type', array(
					'options' => array('Alfanumérico', 'Numérico', 'Texto'),
					'empty' => '(Tipo)',
					'label' => array( 'text' => __('Tipo:'),'class' => 'control-label' )
					)
				     );?>				     
		
		<?php echo $this->Form->hidden('cateventstype_id', array('default'=>$eventstype['EventsType']['id']));?>
		<?php echo $this->Form->end('Guardar'); ?>
	<hr>
	<table class="table table-bordered">
		<thead>
			<tr>
				<th>Nombre</th>
				<th>orden</th>
				<th>Tipo</th>
				<th colspan="2"></th>
			</tr>
		</thead>
		<tbody>
			<?php foreach($eventstype['EventsTypeFields'] as $field):?>				
				<tr>
					<td><?php echo $field['name']?></td>
					<td><?php echo $field['order']?></td>
					<td><?php echo $field['type']?></td>
					<td style="text-align: center;"><i class="icon-edit"></i></td>
					<td style="text-align: center;"><i class="icon-trash"></i> </td>
				</tr>
			<?php endforeach;?>
		</tbody>
	</table>
</div>	